1. Field of Invention
The present invention relates to a technology for processing a microscope image, and more particularly to a method for color correction of a pair of colorful stereo microscope images.
2. Description of Related Arts
In an image acquisition procedure of a stereo microscope, since there are some differences between sensors of a left channel and a right channel of CMOS (Complementary Metal Oxide Semiconductor), a pair of colorful stereo microscope images acquired may have a great color difference. The color difference between the pair of colorful stereo microscope images will affect accuracy of stereo matching. If the color difference is obvious, disparity information of the pair of colorful stereo microscope images can not be obtained accurately, and without the accurate disparity information, a three-dimensional reconstruction can not be successfully completed, and then a three-dimensional measurement is directly affected. Therefore, in order to eliminate the color difference between the pair of colorful stereo microscope images, it is necessary to add intelligent image processing after machine imaging for correcting the color of aberrated images.
A core of eliminating the color difference is how to transmit color information of a reference image to the aberrated images in such a manner that the colors of the two images basically agree with each other.
At present, the method based on color transfer for correcting the colors is mainly based on globally linear color transfer, comprising steps of: transforming color space, wherein RGB color space with strong correlation is transformed into lαβ color space with weak correlation; correcting the colors of the aberrated images in the lαβ color space by utilizing variances of the reference image and the aberrated image, wherein color values of a 1 color channel, an α color channel and a β color channel of each pixel of the corrected image are denoted respectively as l″, α″ and β″, wherein
            l      ″        =                            δ          t                      l            ′                                    δ          s                      l            ′                              ⁢              l        *              ,          ⁢            α      ″        =                            δ          t                      α            ′                                    δ          s                      α            ′                              ⁢              α        *              ,          ⁢            β      ″        =                            δ          t                      β            ′                                    δ          s                      β            ′                              ⁢              β        *              ,wherein l*=l′− l′, α*=α′− α′ and β*=β′− β′, the color values of the 1 color channel, the α color channel and the β color channel of each pixel of the aberrated image are denoted respectively as l′, α′ and β′, average color values of the 1 color channel, the α color channel and the β color channel of each pixel of the aberrated image are denoted respectively as l′, α′ and β′, the variances of the color values of the 1 color channel, the α color channel and the β color channel of each pixel of the aberrated image are denoted respectively as δtl′, δtα′ and δtβ′, the variances of the color values of the 1 color channel, the α color channel and the β color channel of each pixel of the reference image are denoted respectively as δsl′, δsα′ and δsβ′. The method for color correction has two main problems that: on one hand, the method is based on globally linear color transfer for color correction, wherein it is not considered that an object area can be separated out from a background area, and the color information of the whole image is evenly transmitted, which may lead to a transmission error of the color information of the object area and the background area in such a manner that accuracy of color correction is decreased; on the other hand, the method is designed for the images and video sequences of natural scenes, and the microscope images are greatly different from the images of the natural scenes, wherein the microscope images need higher accuracy in processing, and the method for color correction can not adapt to a high accuracy requirement of the microscope images.